#pragma once
#include <vector>
#include <SFML\Graphics.hpp>
#include "Octopi.h"
#include <cmath>
#include <cstdlib>
#include <ctime>
#include "Player.h"
#include "TextManager.h"

class EnemyManager {
public:
	EnemyManager();
	~EnemyManager();

	void Initialize(sf::RenderWindow* win);
	void Update(Player*	player, TextManager* textManager);
	void Cleanup();
	std::vector<Octopi*> m_arrayOfOctopi;

	unsigned int octopiCount;

	bool side;
	int random_integer;

	float spawnRate;
	float timeBetweenSpawns;

	unsigned int numberOfEnemies;
	unsigned int wave;
private:


	sf::Texture* m_octTexture;
	sf::Texture* m_octTextureAtc;
	sf::Texture* m_shkTexture;
	sf::Texture* m_shkTextureAtc;
	sf::Texture* m_shkTextureAtc2;
	sf::Texture* m_shkTextureDead;
	sf::Texture* m_dlpTexture;
	sf::Texture* m_dlpTextureAtc;

	sf::Texture* m_bloodTexture;

	sf::Texture* m_splashTexture;
	sf::Texture* m_takeDamageTexture;
	
	sf::RenderWindow* m_renderWindow;
	bool alreadyOnLeft;
	bool alreadyOnRight;
	sf::Clock* m_spawnClock;
	sf::Clock* m_spawnDelayClock;
	int totalEnemiesSpawned;

	bool friendly;
};
